package chapter_2.demo_2;

/**
 * @author: hero生仔
 */
public class AppleSimpleFormatter implements Predicate {
    @Override
    public String test(Apple apple) {
        String str = apple.weight > 150 ? "heavy" : "light";
        return "A " + str + " " + apple.color + " apple ";
    }
}
